// 新增工具函数，检测cookie有效性
import axios from 'axios'

export const checkBiliCookie = async () => {
  try {
    // 假设后端有/api/bili/check_cookie接口，返回{success:true, valid:true/false}
    const res = await axios.get('/api/bili/check_cookie')
    return res.data && res.data.valid
  } catch {
    return false
  }
}
